package com.qqhf.hitfood.bean.entity;

import com.qqhf.common.entity.Constants;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class AcctInfo {
    //id
    private Integer id;
    //用户名
    private String name;
    //密码
    private String password;
    //权限id
    private Integer roleId;
    //账号状态id
    private Integer stId;
    //所属店铺id
    private Integer shopId;

    public boolean isAdmin() {
        return Constants.ACCT_ROLE_ADMIN == roleId;
    }

    public boolean isWaiter() {
        return Constants.ACCT_ROLE_WAITER == roleId;
    }

    public boolean isUser() {
        return Constants.ACCT_ROLE_USER == roleId;
    }

}
